import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 邓大帅
 * Date: 2023-01-03
 * Time: 21:20
 */
public class Login {
    public static void main(String[] args) throws LoginErrorExcepetion {
        System.out.println("请输入密码：");
        Scanner input = new Scanner(System.in);
        String S = "5201314";
        String s = input.nextLine();
        try {
            if (S.equals(s)) {
                System.out.println("登陆成功");
            }else {
                throw new LoginErrorExcepetion("密码错误");
            }
        } catch (LoginErrorExcepetion a) {
            a.printStackTrace();
        }
    }
}

